home *** CD-ROM | disk | FTP | other *** search
/ Champak Vol A-4 / (Vol A-4) Vol. A4.iso / Games / puppy_red.swf / scripts / DefineSprite_350 / frame_12 / DoAction.as
Text File  |  2008-03-11  |  950b  |  51 lines

  1. function itemZero()
  2. {
  3.    var i = 0;
  4.    while(i < 10)
  5.    {
  6.       _root["uitem" + i] = 0;
  7.       i++;
  8.    }
  9. }
  10. _root.shoot = 0;
  11. stop();
  12. _root.onEnterFrame = null;
  13. var x = 1;
  14. while(x <= 6)
  15. {
  16.    var y = 1;
  17.    while(y <= 6)
  18.    {
  19.       _root["redflag" + x + y].removeMovieClip();
  20.       _root["blueflag" + x + y].removeMovieClip();
  21.       _root["trap" + x + y].removeMovieClip();
  22.       y++;
  23.    }
  24.    x++;
  25. }
  26. _root.tempscore = _root.score;
  27. if(_root.item3 == 1)
  28. {
  29.    _root.score *= 2;
  30. }
  31. else if(_root.item4 == 1)
  32. {
  33.    _root.score *= 3;
  34. }
  35. else if(_root.item5 == 1)
  36. {
  37.    _root.score *= 5;
  38. }
  39. if(_root.userlevel == _root.originallevel && _root.userlevel == 1 && _root.stg > 5)
  40. {
  41.    _root.levelup = 1;
  42. }
  43. else if(_root.userlevel == _root.originallevel && _root.userlevel == 2 && _root.stg > 6)
  44. {
  45.    _root.levelup = 1;
  46. }
  47. _root.sendScore();
  48. stopAllSounds();
  49. finalScoreView.scoreView.scoreView(_root.tempscore);
  50. itemZero();
  51.